<style>
	.boor{
		
	}
	.grend{
		color:#54D3AE ;
	}
	.blud{
		color:#5D9EFF ;
	}
	.yeloow{
		color:#FFC066
	}
	.workload_01{
		height: 100px;
		box-shadow: 0 0px 8px 0 rgba(0, 0, 0, 0.06), 0 1px 0px 0 rgba(0, 0, 0, 0.02);
	    border-radius: 5px;
	    background-color: #ffffff;
		width: 90%;
		text-align: center;
	}
	.workload_01>div:nth-of-type(1){
		
		float: left;
	}
	.workload_01>div:nth-of-type(2){
		padding-top: 20px;
		font-size: 16px;
		
	}
	.workload_01>div:nth-of-type(3){
		padding-top: 10px;
		font-size: 16px;
		
	}
	.activess{
		
		background: url(../management/img/menu-active01.png) no-repeat scroll  !important;
		background-size:100% 100% !important;
    	text-decoration: none;
    	position: absolute;
    	width: 20px;
    	height: 100px;
	}
	.label_001{
	background: #4092e8;
    height: 13px;
    width: 8px;
    display: inline-block;
	}
	.bluds{
		color:#5D9EFF ;
	}
	
</style>
<div id="content-header">
    <div id="breadcrumb"> <a  title="Go to Home" class="tip-bottom"><i class="icon-home"></i> 工作量</a> 
    	<a ui-sref="home.workload" class="current">个人首页</a> </div>
  </div>
  <div class="container-fluid">
    <div class="row-fluid">
      <div class="span12">
			<div class="widget-box">
          <div class="widget-content nopadding">
          		<div style="float: left; width: 20%;" class="">
          			 <div class="workload_01 " ng-click="search(0,0)">
          			 	<div  ng-class="{0:'activess'}[tState]" ></div>
          			 	<div><li class="icon iconfont icon-benzhoudaichuli"></li> 待处理任务</div>
          			 	<div ng-class="{0:'bluds'}[tState]"  style="font-size: 20px;">{{dwc}}</div>
          			 </div>
                	<div class="workload_01 " ng-click="search(0,1)">
          			 	<div  ng-class="{1:'activess'}[tState]" class=""></div>
          			 	<div><li class="icon iconfont icon-yichuli"></li> 已完成任务</div>
          			 	<div  ng-class="{1:'bluds'}[tState]" style="font-size: 20px;">{{ywc}}</div>
          			 </div>
                
          			
          		</div>
          		
                <div  style="float: left; width: 80%;" ng-if="tState==0">
                	<div style="margin: 0 0 20px 0px;"><span class="label_001"></span> 任务列表</div>
                	<div class="btn  btn-primary btnheight" style="line-height: 26px; margin-bottom: 20px;"  ng-click="columnAdd('','add')">添加任务</div>
                	  <table class="table table-bordered data-table">
			              <thead>
			                <tr>
			                  <th width="20%" >任务名称</th>
			                  <th width="10%">项目名称</th>
			                  <th width="10%">添加人</th>
			                  <th width="10%">任务开始时间</th>
			                  <th width="10%">任务结束时间</th>
			                  <th width="10%">任务工作量</th>
			                  <th width="10%">任务类型</th>
			                  <th>操作</th>
			                </tr>
			              </thead>
			              <tbody>
			                <tr class="gradeX" bindonce ng-repeat="o in list">
			                	  <td bo-text="o.tName"></td>
				                  <td bo-text="o.tProName"></td>
				                  <td bo-text="o.tCreatePeopleName"></td>
				                  <td bo-text="o.tStartTime|dateValue"></td>
				                  <td bo-text="o.tEndTime|dateValue"></td>
				                  <td bo-text="o.tWorkload"></td>
				                   <td >
				                   	<span ng-if="o.tType==0" class="grend">项目</span>
                   					<span ng-if="o.tType==1" class="blud">维护</span>
				                   </td>
			                  <td>
			                  	<button class="btn  btn-primary" ng-click="columnXQ(o.tId,'up')">处理</button>
			                  </td>
			                </tr>
			                 <tr class="gradeX"  ng-if="totalSize==0||totalSize==undefined"  class="even">
				            	<td colspan="8"> 暂无数据</td>
				           	</tr>
			              </tbody>
			            </table>
			            
			             <div class="fy" ng-if="totalSize>0">
												<p>共<span>{{totalSize}}</span>条记录，<span>{{pageNum}}</span>/<span>{{totalNum}}</span>页</p>
												<ul uib-pagination 
													first-text="首页" 
													last-text='末页' 
													next-text='下一页' 
													previous-text='上一页' 
													total-items="totalSize" 
													items-per-page='pageSize' 
													boundary-link-numbers='true' 
													max-size='3' boundary-links='true' 
													ng-model="$parent.tj.current" 
													ng-change='search(tj.current)'>
												</ul>
												<p>到第<input placeholder="{{pageNum}}" ng-change="pageUp()" ng-model="$parent.tj.page" />页</p>
												<span ng-click="toPage($parent.tj.page)">前往</span>
						</div>
			                	
                    
                
          </div>
            <div  style="float: left; width: 80%;" ng-if="tState==1">
                	<div style="margin: 0 0 20px 0px;"><span class="label_001"></span> 任务列表</div>
                	  <table class="table table-bordered data-table">
			              <thead>
				            <tr>
			                  <th width="10%" >任务名称</th>
			                  <th width="10%">项目名称</th>
			                  <th width="10%">添加人</th>
			                  <th width="10%">任务开始时间</th>
			                  <th width="10%">任务结束时间</th>
			                  <th width="10%">任务工作量</th>
			                  <th width="10%">任务类型</th>
			                  <th width="10%">操作</th>
			                </tr>
			              </thead>
			              <tbody>
			                <tr class="gradeX" bindonce ng-repeat="o in list">
			                       <td bo-text="o.tName"></td>
				                  <td bo-text="o.tProName"></td>
				                  <td bo-text="o.tCreatePeopleName"></td>
				                  <td bo-text="o.tStartTime|dateValue"></td>
				                  <td bo-text="o.tEndTime|dateValue"></td>
				                  <td bo-text="o.tWorkload"></td>
				                   <td >
				                   	<span ng-if="o.tType==0" class="grend">项目</span>
                   					<span ng-if="o.tType==1" class="blud">维护</span>
				                   </td>
			                  <td>
			                  	<button class="btn  btn-primary" ng-click="columnXQ(o.tId,'add')">详情</button>
			                  </td>
			                </tr>
			                 <tr class="gradeX"  ng-if="totalSize==0||totalSize==undefined"  class="even">
				            	<td colspan="8"> 暂无数据</td>
				           	</tr>
			              </tbody>
			            </table>
			            
			             <div class="fy" ng-if="totalSize>0">
												<p>共<span>{{totalSize}}</span>条记录，<span>{{pageNum}}</span>/<span>{{totalNum}}</span>页</p>
												<ul uib-pagination 
													first-text="首页" 
													last-text='末页' 
													next-text='下一页' 
													previous-text='上一页' 
													total-items="totalSize" 
													items-per-page='pageSize' 
													boundary-link-numbers='true' 
													max-size='3' boundary-links='true' 
													ng-model="$parent.tj.current" 
													ng-change='search(tj.current)'>
												</ul>
												<p>到第<input placeholder="{{pageNum}}" ng-change="pageUp()" ng-model="$parent.tj.page" />页</p>
												<span ng-click="toPage($parent.tj.page)">前往</span>
						</div>
			                	
               
                
                
                </div>
        </div>
      </div>
  </div>

<script type="text/ng-template" id="workXQ.html">
			<style>
				.modal-content{
					width: 600px;
					margin-left: 180px;
				}
				.table_input{
					width:256px;text-indent: .1rem;height: 36px;
				}
				.table_span{
					display: block;width:100px;
				}
				
			</style>
			<div class="modal-header" style="text-align: center;font-size: 24px;background: #4092E8;color: white;height:50px;line-height: 50px">
				<div style="margin-top: -8px;">
					详情
				</div>
				<button style="color:white;float: right;background: #4092e8;border: none;outline: none;box-shadow: none;margin-top: -35px;" class="btn " type="button" ng-click="cancel()">[关闭]</button>
			</div>
			<div class="modal-body" >
				<div class="adduser" >

					<div style="    margin-left: 40px;">
						<form novalidate="novalidate" name="form">
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >任务名称：</span>
								<input class="table_input"    type="text" value="" name="tName" ng-model="param.tName" required>
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >项目名称：</span>
								<input class="table_input"    type="text" value="" ng-model="param.tProName" >
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >指派人员姓名：</span>
								
                    			<input class="table_input"    type="text" value="" name="tName" ng-model="param.tDesigneeName" >
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >添加人姓名：</span>
								
                    			<input class="table_input"    type="text" value="" name="tName" ng-model="param.tCreatePeopleName" >
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >任务开始时间：</span>
								<input class="table_input"    type="text" value="" name="tName" ng-model="param.tStartTime" >
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >任务结束时间：</span>
								<input class="table_input"    type="text" value="" name="tName" ng-model="param.tEndTime" >
							</div>
							
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >任务类型：</span>
								<input class="table_input" ng-if="param.tType==0"   type="text" value="项目" name="tName" />
								<input class="table_input"  ng-if="param.tType==1"   type="text" value="维护" />
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >工作量：</span>
								<input class="table_input"    type="text" value="" name="tWorkload" ng-model="param.tWorkload"  required>
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >状态：</span>
								<input class="table_input" ng-if="param.tState==0"   type="text" value="未完成"  />
								<input class="table_input"  ng-if="param.tState==1"   type="text" value="完成" />
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >详细描述：</span>
								<textarea class="table_input"    type="text" value="" name="cProduct" ng-model="param.tDetail" />
							</div>
							
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >图片：</span>
								<div class="upload">
										<div ng-repeat="f in param.taskImageList">
											<img   ng-src="{{f.tiUrl|imgs}}" ng-click="imgYl(f.tiUrl|imgs)"/>
										</div>
									 	
								</div>
							</div>
							
							
							
						</form>

					</div>
				</div>
			</div>
			<div class="modal-footer" style="position: relative;height:50px;" ng-if="iss">
				<div style="display: flex;justify-content: flex-end;padding: 0;position: absolute;right: 20px;top: 0.1rem;">
					
					<button  class="" ng-disabled="form.$invalid||param.cType==''" ng-class="{true:'btn btn-primary'}[form.$invalid||param.cType=='']" 
						style="width: 100px;border-radius: 0;line-height: 32px;background-color:#4092e8 ;border:#4092e8 ; font-size: 13px;color: white;font-size: 14px;"
						ng-click="ok(form.$invalid)">完成</button>
				</div>
			</div>
		</script>
		
<script type="text/ng-template" id="workAdds.html">
			<style>
				.modal-content{
					width: 600px;
					margin-left: 180px;
				}
				.table_input{
					width:256px;text-indent: .1rem;height: 36px;
				}
				.table_span{
					display: block;width:100px;
				}
				
			</style>
			<div class="modal-header" style="text-align: center;font-size: 24px;background: #4092E8;color: white;height:50px;line-height: 50px">
				<div style="margin-top: -8px;">
					{{sername}}
				</div>
				<button style="color:white;float: right;background: #4092e8;border: none;outline: none;box-shadow: none;margin-top: -35px;" class="btn " type="button" ng-click="cancel()">[关闭]</button>
			</div>
			<div class="modal-body" >
				<div class="adduser" >

					<div style="    margin-left: 40px;">
						<form novalidate="novalidate" name="form">
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >任务名称：</span>
								<input class="table_input"    type="text" value="" name="tName" ng-model="param.tName" required>
								<span class="error bigError "  ng-show="form.tName.$error.required" style="font-size: 18px;font-weight: bold;">*</span>
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >项目名称：</span>
								<select  class="table_input"  name="tProId" ng-model="param.tProId"   required
                    			ng-options="o.diId as o.diName for o in typeDic"></select>
                    			<span class="error bigError "  ng-show="form.tProId.$error.required" style="font-size: 18px;font-weight: bold;">*</span>
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >任务开始时间：</span>
								<model-picker class=""  name="pickertime" ng-model="pickertime" required ></model-picker>
								<span class="error bigError "  ng-show="form.pickertime.$error.required" style="font-size: 18px;font-weight: bold;">*</span>
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >任务结束时间：</span>
								<model-pickers class=""  name="pickertimes"  ng-model="pickertimes" required ></model-pickers>
								<span class="error bigError "  ng-show="form.pickertimes.$error.required" style="font-size: 18px;font-weight: bold;">*</span>
							</div>
							
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >任务类型：</span>
								<select  class="table_input"  name="tType" ng-model="param.tType"  required
                    			>
                    			<option value="">请选择</option>
								<option value="0"  ng-selected="param.tType==0">项目</option>
								<option value="1"  ng-selected="param.tType==1">维护</option>
								</select>
                    			<span class="error bigError "  ng-show="form.tType.$error.required" style="font-size: 18px;font-weight: bold;">*</span>
							</div>
							
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >详细描述：</span>
								<textarea class="table_input"    type="text" value="" name="cProduct" ng-model="param.tDetail" />
							</div>
							
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" >图片：</span>
								<form style="display: inline-block;" >
								<div  class="btn  btn-primary"    ngf-select ngf-change="submit()" ng-model="file" name="file" 
									 ngf-max-size="20MB" ngf-min-size="0KB"  ngf-accept="'image/*'" ngf-multiple="true">上传</div>
									 
									 
								
							 </form>
							</div>
							<div style="margin: 10px 0;display: flex;align-items: center;">
								<span class="table_span" ></span>
								<div class="upload">
										<div ng-repeat="f in param.taskImageList">
											 <i class="icon iconfont icon-cheng" ng-click="delimg(f.tiUrl,f)"></i>
											<img   ng-src="{{f.tiUrl|imgs}}" ng-click="imgYl(f.tiUrl|imgs)"/>
										</div>
									 	
								</div>
									 
								
							 </form>
							</div>
							
							
						</form>

					</div>
				</div>
			</div>
			<div class="modal-footer" style="position: relative;height:50px;">
				<div style="display: flex;justify-content: flex-end;padding: 0;position: absolute;right: 20px;top: 0.1rem;">
					
					<button  class="" ng-disabled="form.$invalid||param.cType==''" ng-class="{true:'btn btn-primary'}[form.$invalid||param.cType=='']" 
						style="width: 100px;border-radius: 0;line-height: 32px;background-color:#4092e8 ;border:#4092e8 ; font-size: 13px;color: white;font-size: 14px;"
						ng-click="ok(form.$invalid)">保 存</button>
				</div>
			</div>
		</script>
<style>
	.upload{
		width: 100%;
	}
	.upload>div>img{
		width: 60px;
		height: 60px;
		max-width: 100%;
		max-height: 100%;
		
	}
	.upload>div>i{
		    position: absolute;
		    font-size: 12px;
	}
	.upload>div{
		margin: 5px;
		width: 60px;
		height: 60px;
		float:left
	}
</style>